package com.itheima.bos.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.itheima.bos.dao.StandardRepository;
import com.itheima.bos.domain.Standard;
import com.itheima.bos.service.StandardService;

@Service
@Transactional
public class StandardServiceImpl implements StandardService{
	//注入dao对象
	@Autowired
	private StandardRepository stanRepository;
	
	@Override
	public void save(Standard standard) {
		stanRepository.save(standard);
		
	}

	@Override
	public Page<Standard> findPageData(Pageable pageable) {
		
		return stanRepository.findAll(pageable);
	}

}
